package com.ruoyi.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.mapper.BaseFriendLinkMapper;
import com.ruoyi.domain.BaseFriendLink;
import com.ruoyi.service.IBaseFriendLinkService;

/**
 * 友情链接Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-05-14
 */
@Service
public class BaseFriendLinkServiceImpl implements IBaseFriendLinkService 
{
    @Autowired
    private BaseFriendLinkMapper baseFriendLinkMapper;

    /**
     * 查询友情链接
     * 
     * @param linkId 友情链接主键
     * @return 友情链接
     */
    @Override
    public BaseFriendLink selectBaseFriendLinkByLinkId(Long linkId)
    {
        return baseFriendLinkMapper.selectBaseFriendLinkByLinkId(linkId);
    }

    /**
     * 查询友情链接列表
     * 
     * @param baseFriendLink 友情链接
     * @return 友情链接
     */
    @Override
    public List<BaseFriendLink> selectBaseFriendLinkList(BaseFriendLink baseFriendLink)
    {
        return baseFriendLinkMapper.selectBaseFriendLinkList(baseFriendLink);
    }

    /**
     * 新增友情链接
     * 
     * @param baseFriendLink 友情链接
     * @return 结果
     */
    @Override
    public int insertBaseFriendLink(BaseFriendLink baseFriendLink)
    {
        return baseFriendLinkMapper.insertBaseFriendLink(baseFriendLink);
    }

    /**
     * 修改友情链接
     * 
     * @param baseFriendLink 友情链接
     * @return 结果
     */
    @Override
    public int updateBaseFriendLink(BaseFriendLink baseFriendLink)
    {
        return baseFriendLinkMapper.updateBaseFriendLink(baseFriendLink);
    }

    /**
     * 批量删除友情链接
     * 
     * @param linkIds 需要删除的友情链接主键
     * @return 结果
     */
    @Override
    public int deleteBaseFriendLinkByLinkIds(Long[] linkIds)
    {
        return baseFriendLinkMapper.deleteBaseFriendLinkByLinkIds(linkIds);
    }

    /**
     * 删除友情链接信息
     * 
     * @param linkId 友情链接主键
     * @return 结果
     */
    @Override
    public int deleteBaseFriendLinkByLinkId(Long linkId)
    {
        return baseFriendLinkMapper.deleteBaseFriendLinkByLinkId(linkId);
    }
}
